<script setup>
	import {
		onLaunch,
		onShow,
		onHide
	} from '@dcloudio/uni-app'

	import LoginApi from './Api/Login.js'

	onLaunch(() => {
		console.log('App onLaunch')
		LoginApi.Check().then(resp => {
			const loginState = resp.data
			if (!loginState) {
				uni.reLaunch({
					url: '/pages/NineBot'
				})
				return
			}
		})
	})

	onShow(() => {
		console.log('App Show')
	})

	onHide(() => {
		console.log('App Hide')
	})
</script>

<style lang="scss">
	/* 注意要写在第一行，同时给style标签加入lang="scss"属性 */
	@import "uview-plus/index.scss";

	@import '/static/iconfont.css';

	page {
		background-color: #f8f9fa;
		padding-bottom: 24px;
	}

	.primary-color {
		color: $uni-color-primary !important;
	}

	.withe-bg {
		background-color: #fff;
	}

	.opacity-sm {
		opacity: 0.8;
	}

	/* 通用字体样式 */
	.font-mini {
		font-size: $uni-font-size-mini;
	}

	.font-sm {
		font-size: $uni-font-size-sm !important;
	}

	.font-base {
		font-size: $uni-font-size-base;
	}

	.font-lg {
		font-size: $uni-font-size-lg;
	}

	.font-bg {
		font-size: $uni-font-size-bg;
	}


	.font-weight-bold {
		font-weight: bolder;
	}

	.font-italic {
		font-style: italic;
	}

	.font-underline {
		text-decoration: underline;
	}

	.font-line-through {
		text-decoration: line-through;
	}

	.font-normal {
		font-weight: normal;
	}
</style>